Example of lambda function in python with list

37

tables = [lambda x=x: x*10 for x in range(1, 11)]
  
for table in tables:
    print(table())

Comments

Submit
0 Comments